---
layout: example
categories: example/v1.0.0
version: v1.0.0
title: Leaflet layers control
description: Use Leaflet's default layer switcher in Mapbox.js.
tags:
  - layers
---
<div id='map'></div>

<script>
var map = L.mapbox.map('map').setView([38.8922,-77.0348], 14);

L.control.layers({
    'Mapbox Streets': L.mapbox.styleLayer('mapbox://styles/mapbox/streets-v11').addTo(map),
    'Mapbox Light': L.mapbox.styleLayer('mapbox://styles/mapbox/light-v10'),
    'Mapbox Outdoors': L.mapbox.styleLayer('mapbox://styles/mapbox/outdoors-v11'),
    'Mapbox Satellite': L.mapbox.styleLayer('mapbox://styles/mapbox/satellite-v9')
}).addTo(map);
</script>
